% script: extreme points and random points in the CS
cs = para_gms;
[N_cs, N_para_fc] = size(cs);
N_interior = n_fc_para_sampled - N_para_fc*2; 
N_interior = N_interior*2; % double just to make sure that we will have enough

para_bd = [];

for k = 1 : N_para_fc
    [~, min_ind_k] = min(cs(:, k));    
    [~, max_ind_k] = max(cs(:, k));
    
    para_bd = [para_bd, cs(min_ind_k, :)'];        
    para_bd = [para_bd, cs(max_ind_k, :)'];  
end

if N_interior>0
    para_bd = [para_bd, cs(randsample(N_cs, N_interior, 'true'), :)'];
end

para_vec = unique(para_bd', 'rows')';

if size(para_vec, 2) < n_fc_para_sampled
    error('n_fc_para_sampled too large')
else
    para_vec = para_vec(:, 1:n_fc_para_sampled);
end